package com.example.demo.entity;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import java.io.Serializable;
import java.time.LocalDateTime;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Getter;
import lombok.Setter;

/**
 * <p>
 * 
 * </p>
 *
 * @author Mr.Abel
 * @since 2024-12-31
 */
@Getter
@Setter
@Schema(name = "User", description = "")
public class User implements Serializable {

    private static final long serialVersionUID = 1L;

    @Schema(description = "id")
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @Schema(description = "用户名")
    private String uname;

    @Schema(description = "密码")
    private String upass;

    @Schema(description = "盐值")
    private String salt;

    @Schema(description = "年龄")
    private Integer age;

    @Schema(description = "年级")
    private Integer grade;

    @Schema(description = "昵称")
    private String nickName;

    @Schema(description = "角色")
    private Integer roleId;

    @Schema(description = "状态")
    private Boolean flag;

    @Schema(description = "创建时间")
    @TableField(fill = FieldFill.INSERT)
    private LocalDateTime createTime;

    @Schema(description = "修改时间")
    @TableField(fill = FieldFill.INSERT_UPDATE)
    private LocalDateTime updateTime;
}
